package com.wangbo.net;

public class TestPing {
    public static void main(String[] args) throws Exception {
        String ipAddress = "58.221.238.181";
//        test01(ipAddress); // true
//        test02(ipAddress);
        test03(ipAddress);
    }

    public static void test01(String ipAddress) {
        System.out.println(PingUtil.ping(ipAddress));
    }

    public static void test02(String ipAddress) {
        PingUtil.ping02(ipAddress);
    }

    public static void test03(String ipAddress) {
        System.out.println(PingUtil.ping(ipAddress, 5, 5000));
    }
}
